package ypx;


public class Student {
    //学生类
    private int id;
    private String name;
    private int age;
    private String address;
    private String gender;

    public Student(String id, String name, int age, String gender, double score) {
        this.id = Integer.parseInt(id);
        this.name = name;
        this.age = age;
        this.address = address;
        this.gender = gender;

    }
    public int getId() {
        return id;
    }

    public int setId(String id) {
        this.id = Integer.parseInt(id);
        return 0;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }
    public String getGender() {
        return gender;
    }

    public void setGender(String gender) {
        this.gender = gender;
    }

    public String getAddress() {
        return address;
    }
     public void setAddress(String gender) {
        this.gender = gender;
    }
    @Override
    public String toString() {
        return String.format("学号:%s 姓名:%s 年龄:%d 性别:%s 地址:%s",
                id, name, age, gender, address);
    }

}
